#pragma once

typedef unsigned long Item;
#include <iostream>
using namespace std;


class Stack
{
public:
	Stack(int n = MAX);
	Stack(const Stack& st);
	~Stack();

	bool isempty()const;
	bool isfull()const;
	bool push(const Item& item);
	bool pop(Item& item);

	Stack& operator=(const Stack& st);
	
	friend ostream& operator<<(ostream& os, const Stack& s);

private:
	enum { MAX = 10 };
	Item* pitems;
	int size;
	int top;
};

